package net.maku.im.vo;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fhs.core.trans.anno.Trans;
import com.fhs.core.trans.constant.TransType;
import com.fhs.core.trans.vo.TransPojo;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import net.maku.framework.common.utils.DateUtils;
import net.maku.im.constant.ImConstant;
import net.maku.im.entity.ImUserEntity;

import java.io.Serializable;
import java.util.Date;

/**
* 群组成员
*
* @author Blue 
* @since 1.0.0 2024-07-14
*/
@Data
@Schema(description = "群组成员")
public class ImGroupMemberVO implements Serializable, TransPojo {
	private static final long serialVersionUID = 1L;

	@Schema(description = "id")
	private Long id;

	@Trans(type = TransType.SIMPLE,dataSource = ImConstant.DS_IM_PLATFORM,target = ImUserEntity.class, fields = "userName", ref = "userName")
	@Schema(description = "用户id")
	private Long userId;

	@Schema(description = "用户名")
	private String userName;

	@Schema(description = "群内昵称")
	private String showNickName;

	@Schema(description = "用户头像")
	private String headImage;

	@Schema(description = "进群时间")
	@JsonFormat(pattern = DateUtils.DATE_TIME_PATTERN)
	private Date createdTime;


}